<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
                      "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
    <title>13 Plugins 2.2.1</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <link rel="stylesheet" href="../css/main.css" type="text/css" media="screen, print" title="Style" charset="utf-8"/>
    <link rel="stylesheet" href="../css/pdf.css" type="text/css" media="print" title="PDF" charset="utf-8"/>
    <script type="text/javascript">
function addJsClass() {
    var classes = document.body.className.split(" ");
    classes.push("js");
    document.body.className = classes.join(" ");
}
    </script>
</head>

<body class="body" onload="addJsClass();">
<div id="navigation">
    <ul>
        <li>
            <div id="nav-summary" onmouseover="toggleNavSummary(false)" onmouseout="toggleNavSummary(true)">
                <a href="../guide/index.html" class="button">Table of contents</a>

                <div id="nav-summary-childs" style="display:none;">
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/introduction.html"><strong>1</strong><span>Introduction</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/gettingStarted.html"><strong>2</strong><span>Getting Started</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/upgradingFromPreviousVersionsOfGrails.html"><strong>3</strong><span>Upgrading from previous versions of Grails</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/conf.html"><strong>4</strong><span>Configuration</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/commandLine.html"><strong>5</strong><span>The Command Line</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/GORM.html"><strong>6</strong><span>Object Relational Mapping (GORM)</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/theWebLayer.html"><strong>7</strong><span>The Web Layer</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/validation.html"><strong>8</strong><span>Validation</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/services.html"><strong>9</strong><span>The Service Layer</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/testing.html"><strong>10</strong><span>Testing</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/i18n.html"><strong>11</strong><span>Internationalization</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/security.html"><strong>12</strong><span>Security</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/plugins.html"><strong>13</strong><span>Plugins</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/webServices.html"><strong>14</strong><span>Web Services</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/spring.html"><strong>15</strong><span>Grails and Spring</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/hibernate.html"><strong>16</strong><span>Grails and Hibernate</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/scaffolding.html"><strong>17</strong><span>Scaffolding</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/deployment.html"><strong>18</strong><span>Deployment</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0"><a href="../guide/contributing.html"><strong>19</strong><span>Contributing to Grails</span></a>
                    </div>
                    
                </div>
            </div>
        </li>
        <li class="separator selected">
            <a id="ref-button" onclick="localToggle(); return false;" href="#">Quick Reference</a>
        </li>
    </ul>
</div>
<div id="header">
    <div class="images clearfix">
        
        <span id="logo"><a href="http://grails.org" target="_blank"><img alt="Grails Logo" title="The Grails Framework" src="../img/grails.png" border="0"/></a></span>
        
        
        <span id="sponsor"><a href="http://springsource.com" target="_blank"><img alt="SpringSource Logo" title="SpringSource - Weapons for the War on Java Complexity" src="../img/springsource-logo.png" border="0"/></a></span>
        
    </div>
    <p>See the light - agile, industrial strength, rapid web application development made easy</p>
</div>


<table id="colset" border="0" cellpadding="0" cellspacing="0">
    <tr>
        <td id="col1">
            <div id="main" class="corner-all">

                
                    <div class="toc-item prev-left"><a href="../guide/security.html">&lt;&lt; <strong>12</strong><span>Security</span></a></div>
                

                <span id='toggle-col1' class="toggle">(<a href="#" onclick="localToggle(); return false;">Quick Reference</a>)</span>

                
                    <div class="toc-item next-right"><a href="../guide/webServices.html"><strong>14</strong><span>Web Services</span> >></a></div>
                


                <div class="project">
                    <h1>13 Plugins - Reference Documentation</h1>

                    <p><strong>Authors:</strong> Graeme Rocher, Peter Ledbrook, Marc Palmer, Jeff Brown, Luke Daley, Burt Beckwith</p>

                    <p><strong>Version:</strong> 2.2.1</p>

                    
                </div>

                
                <div id="table-of-content">
                    <h2>Table of Contents</h2>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#creatingAndInstallingPlugins"><strong>13.1</strong><span>Creating and Installing Plugins</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#repositories"><strong>13.2</strong><span>Plugin Repositories</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#understandingPluginStructure"><strong>13.3</strong><span>Understanding a Plugin's Structure</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#providingBasicArtefacts"><strong>13.4</strong><span>Providing Basic Artefacts</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#evaluatingConventions"><strong>13.5</strong><span>Evaluating Conventions</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#hookingIntoBuildEvents"><strong>13.6</strong><span>Hooking into Build Events</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#hookingIntoRuntimeConfiguration"><strong>13.7</strong><span>Hooking into Runtime Configuration</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#addingDynamicMethodsAtRuntime"><strong>13.8</strong><span>Adding Dynamic Methods at Runtime</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#participatingInAutoReloadEvents"><strong>13.9</strong><span>Participating in Auto Reload Events</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#understandingPluginLoadOrder"><strong>13.10</strong><span>Understanding Plugin Load Order</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#artefactApi"><strong>13.11</strong><span>The Artefact API</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:10px"><a href="#queryingArtefacts"><strong>13.11.1</strong><span>Asking About Available Artefacts</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:10px"><a href="#customArtefacts"><strong>13.11.2</strong><span>Adding Your Own Artefact Types</span></a>
                    </div>
                    
                    <div class="toc-item" style="margin-left:0px"><a href="#binaryPlugins"><strong>13.12</strong><span>Binary Plugins</span></a>
                    </div>
                    
                </div>
                

                
<a name="12. Plug-ins"><!-- Legacy link --></a>
<h1 id="plugins">13 Plugins</h1>
Grails is first and foremost a web application framework, but it is also a platform. By exposing a number of extension points that let you extend anything from the command line interface to the runtime configuration engine, Grails can be customised to suit almost any needs. To hook into this platform, all you need to do is create a plugin.<p class="paragraph"/>Extending the platform may sound complicated, but plugins can range from trivially simple to incredibly powerful. If you know how to build a Grails application, you'll know how to create a plugin for <a href="../guide/single.html#providingBasicArtefacts" class="guide">sharing a data model</a> or some static resources.


<a name="12.1 Creating and Installing Plug-ins"><!-- Legacy link --></a>
<h2 id="creatingAndInstallingPlugins">13.1 Creating and Installing Plugins</h2>
<h4>Creating Plugins</h4><p class="paragraph"/>Creating a Grails plugin is a simple matter of running the command:<p class="paragraph"/><div class="code"><pre>grails create&#45;plugin &#91;PLUGIN NAME&#93;</pre></div><p class="paragraph"/>This will create a plugin project for the name you specify. For example running <code>grails create-plugin example</code> would create a new plugin project called <code>example</code>.<p class="paragraph"/>The structure of a Grails plugin is very nearly the same as a Grails application project's except that in the root of the plugin directory you will find a plugin Groovy file called the "plugin descriptor".<p class="paragraph"/><blockquote class="note">
The only plugins included in a new plugin project are Tomcat and Release. Hibernate is not included by default.
</blockquote><p class="paragraph"/>Being a regular Grails project has a number of benefits in that you can immediately test your plugin by running:<p class="paragraph"/><div class="code"><pre>grails run&#45;app</pre></div><p class="paragraph"/><blockquote class="note">
Plugin projects don't provide an index.gsp by default since most plugins don't need it. So, if you try to view the plugin running in a browser right after creating it, you will receive a page not found error. You can easily create a <code>grails-app/views/index.gsp</code> for your plugin if you'd like.
</blockquote><p class="paragraph"/>The plugin descriptor name ends with the convention <code>GrailsPlugin</code> and is found in the root of the plugin project. For example:<p class="paragraph"/><div class="code"><pre>class ExampleGrailsPlugin &#123;
   def version = <span class="java&#45;quote">"0.1"</span><p class="paragraph"/>   &#8230;
&#125;</pre></div><p class="paragraph"/>All plugins must have this class in the root of their directory structure. The plugin class defines the version of the plugin and other metadata, and optionally various hooks into plugin extension points (covered shortly).<p class="paragraph"/>You can also provide additional information about your plugin using several special properties:
<ul class="star">
<li><code>title</code> - short one-sentence description of your plugin</li>
<li><code>version</code> - The version of your plugin. Valid values include example "0.1", "0.2-SNAPSHOT", "1.1.4" etc.</li>
<li><code>grailsVersion</code> - The version of version range of Grails that the plugin supports. eg. "1.2 &#62; *" (indicating 1.2 or higher)</li>
<li><code>author</code> - plugin author's name</li>
<li><code>authorEmail</code> - plugin author's contact e-mail</li>
<li><code>description</code> - full multi-line description of plugin's features</li>
<li><code>documentation</code> - URL of the plugin's documentation</li>
</ul><p class="paragraph"/>Here is an example from the <a href="http://grails.org/plugin/quartz" target="blank">Quartz Grails plugin</a>:<p class="paragraph"/><div class="code"><pre>class QuartzGrailsPlugin &#123;
    def version = <span class="java&#45;quote">"0.1"</span>
    def grailsVersion = <span class="java&#45;quote">"1.1 &#62; &#42;"</span>
    def author = <span class="java&#45;quote">"Sergey Nebolsin"</span>
    def authorEmail = <span class="java&#45;quote">"nebolsin@gmail.com"</span>
    def title = <span class="java&#45;quote">"Quartz Plugin"</span>
    def description = '''&#92;
The Quartz plugin allows your Grails application to schedule jobs&#92;
to be executed using a specified interval or cron expression. The&#92;
underlying system uses the Quartz Enterprise Job Scheduler configured&#92;
via Spring, but is made simpler by the coding by convention paradigm.&#92;
'''
    def documentation = <span class="java&#45;quote">"http://grails.org/plugin/quartz"</span><p class="paragraph"/>   &#8230;
&#125;</pre></div><p class="paragraph"/><h4>Installing and Distributing Plugins</h4><p class="paragraph"/>To distribute a plugin you navigate to its root directory in a console and run:<p class="paragraph"/><div class="code"><pre>grails <span class="java&#45;keyword">package</span>&#45;plugin</pre></div><p class="paragraph"/>This will create a zip file of the plugin starting with <code>grails-</code> then the plugin name and version. For example with the example plugin created earlier this would be <code>grails-example-0.1.zip</code>. The <code>package-plugin</code> command will also generate a <code>plugin.xml</code> file which contains machine-readable information about plugin's name, version, author, and so on.<p class="paragraph"/>Once you have a plugin distribution file you can navigate to a Grails project and run:<p class="paragraph"/><div class="code"><pre>grails install&#45;plugin /path/to/grails&#45;example&#45;0.1.zip</pre></div><p class="paragraph"/>If the plugin is hosted on an HTTP server you can install it with:<p class="paragraph"/><div class="code"><pre>grails install&#45;plugin http://myserver.com/plugins/grails&#45;example&#45;0.1.zip</pre></div><p class="paragraph"/><h4>Notes on excluded Artefacts</h4><p class="paragraph"/>Although the <a href="../ref/Command Line/create-plugin.html" class="commandLine">create-plugin</a> command creates certain files for you so that the plugin can be run as a Grails application, not all of these files are included when packaging a plugin. The following is a list of artefacts created, but not included by <a href="../ref/Command Line/package-plugin.html" class="commandLine">package-plugin</a>:
<ul class="star">
<li><code>grails-app/conf/BootStrap.groovy</code></li>
<li><code>grails-app/conf/BuildConfig.groovy</code> (although it is used to generate <code>dependencies.groovy</code>)</li>
<li><code>grails-app/conf/Config.groovy</code></li>
<li><code>grails-app/conf/DataSource.groovy</code> (and any other <code>*DataSource.groovy</code>)</li>
<li><code>grails-app/conf/UrlMappings.groovy</code></li>
<li><code>grails-app/conf/spring/resources.groovy</code></li>
<li>Everything within <code>/web-app/WEB-INF</code></li>
<li>Everything within <code>/web-app/plugins/&#42;&#42;</code></li>
<li>Everything within <code>/test/&#42;&#42;</code></li>
<li>SCM management files within <code>&#42;&#42;/.svn/&#42;&#42;</code> and <code>&#42;&#42;/CVS/&#42;&#42;</code></li>
</ul><p class="paragraph"/>If you need artefacts within <code>WEB-INF</code> it is recommended you use the <code>_Install.groovy</code> script (covered later), which is executed when a plugin is installed, to provide such artefacts. In addition, although <code>UrlMappings.groovy</code> is excluded you are allowed to include a <code>UrlMappings</code> definition with a different name, such as <code>MyPluginUrlMappings.groovy</code>.<p class="paragraph"/><h4>Specifying Plugin Locations</h4><p class="paragraph"/>An application can load plugins from anywhere on the file system, even if they have not been installed. Specify the location of the (unpacked) plugin in the application's <code>grails-app/conf/BuildConfig.groovy</code> file:<p class="paragraph"/><div class="code"><pre>// Useful to test plugins you are developing.
grails.plugin.location.shiro =
        <span class="java&#45;quote">"/home/dilbert/dev/plugins/grails&#45;shiro"</span><p class="paragraph"/>// Useful <span class="java&#45;keyword">for</span> modular applications where all plugins and
// applications are in the same directory.
grails.plugin.location.'grails&#45;ui' = <span class="java&#45;quote">"../grails&#45;grails&#45;ui"</span></pre></div><p class="paragraph"/>This is particularly useful in two cases:
<ul class="star">
<li>You are developing a plugin and want to test it in a real application without packaging and installing it first.</li>
<li>You have split an application into a set of plugins and an application, all in the same "super-project" directory.</li>
</ul><p class="paragraph"/><h4>Global plugins</h4><p class="paragraph"/>Plugins can also be installed globally for all applications for a particular version of Grails using the <code>&#45;global</code> flag, for example:<p class="paragraph"/><div class="code"><pre>grails install&#45;plugin webtest &#45;global</pre></div><p class="paragraph"/>The default location is &#36;USER_HOME/.grails/&#60;grailsVersion&#62;/global-plugins but this can be customized with the <code>grails.global.plugins.dir</code> setting in <code>BuildConfig.groovy</code>.


<a name="12.2 Plugin Repositories"><!-- Legacy link --></a>
<h2 id="repositories">13.2 Plugin Repositories</h2>
<h4>Distributing Plugins in the Grails Central Plugin Repository</h4><p class="paragraph"/>The preferred way to distribute plugin is to publish to the official Grails Central Plugin Repository. This will make your plugin visible to the <a href="../ref/Command Line/list-plugins.html" class="commandLine">list-plugins</a> command:<p class="paragraph"/><div class="code"><pre>grails list&#45;plugins</pre></div><p class="paragraph"/>which lists all plugins that are in the central repository. Your plugin will also be available to the <a href="../ref/Command Line/plugin-info.html" class="commandLine">plugin-info</a> command:<p class="paragraph"/><div class="code"><pre>grails plugin&#45;info &#91;plugin&#45;name&#93;</pre></div><p class="paragraph"/>which prints extra information about it, such as its description, who wrote, etc.<p class="paragraph"/><blockquote class="note">
If you have created a Grails plugin and want it to be hosted in the central repository, you'll find instructions for getting an account on <a href="http://grails.org/Creating+Plugins" target="blank">this wiki page</a>.
</blockquote><p class="paragraph"/>When you have access to the Grails Plugin repository, install the <a href="http://grails-plugins.github.com/grails-release/docs/index.html" target="blank">Release Plugin</a> and execute the <code>publish-plugin</code> command to release your plugin:<p class="paragraph"/><div class="code"><pre>grails install&#45;plugin release
grails publish&#45;plugin</pre></div><p class="paragraph"/>This will automatically commit any remaining source code changes to your SCM provider and then publish the plugin to the central repository. If the command is successful, it will immediately be available on the plugin portal at http://grails.org/plugin/&#60;pluginName&#62;. You can find out more about the Release plugin and its other features in <a href="http://grails-plugins.github.com/grails-release/docs/index.html" target="blank">its user guide</a>.<p class="paragraph"/><h4>Configuring Additional Repositories</h4><p class="paragraph"/>The process for configuring repositories in Grails differs between versions. For version of Grails 1.2 and earlier please refer to the <a href="http://grails.org/doc/1.2.x/guide/12.%20Plug-ins.html#12.2%20Plugin%20Repositories" target="blank">Grails 1.2 documentation</a> on the subject. The following sections cover Grails 1.3 and above.<p class="paragraph"/>Grails 1.3 and above use Ivy under the hood to resolve plugin dependencies. The mechanism for defining additional plugin repositories is largely the same as <a href="../guide/single.html#ivy" class="guide">defining repositories for JAR dependencies</a>. For example you can define a remote Maven repository that contains Grails plugins using the following syntax in <code>grails-app/conf/BuildConfig.groovy</code>:<p class="paragraph"/><div class="code"><pre>repositories &#123;
    mavenRepo <span class="java&#45;quote">"http://repository.codehaus.org"</span><p class="paragraph"/>    // ...or with a name
    mavenRepo name: <span class="java&#45;quote">"myRepo"</span>,
              root: <span class="java&#45;quote">"http://myserver:8081/artifactory/plugins&#45;snapshots&#45;local"</span>
&#125;</pre></div><p class="paragraph"/>You can also define a SVN-based Grails repository (such as the one hosted at <a href="http://plugins.grails.org/" target="blank">http://plugins.grails.org</a>) using the <code>grailsRepo</code> method:<p class="paragraph"/><div class="code"><pre>repositories &#123;
    grailsRepo <span class="java&#45;quote">"http://myserver/mygrailsrepo"</span><p class="paragraph"/>    // ...or with a name
    grailsRepo <span class="java&#45;quote">"http://myserver/svn/grails&#45;plugins"</span>, <span class="java&#45;quote">"mySvnRepo"</span> 
&#125;</pre></div><p class="paragraph"/>There is a shortcut to setup the Grails central repository:<p class="paragraph"/><div class="code"><pre>repositories &#123;
    grailsCentral()
&#125;</pre></div><p class="paragraph"/>The order in which plugins are resolved is based on the ordering of the repositories. So in this case the Grails central repository will be searched last:<p class="paragraph"/><div class="code"><pre>repositories &#123;
    grailsRepo <span class="java&#45;quote">"http://myserver/mygrailsrepo"</span>
    grailsCentral()
&#125;</pre></div><p class="paragraph"/>All of the above examples use HTTP; however you can specify any <a href="http://ant.apache.org/ivy/history/latest-milestone/settings/resolvers.html" target="blank">Ivy resolver</a> to resolve plugins with. Below is an example that uses an SSH resolver:<p class="paragraph"/><div class="code"><pre>def sshResolver = <span class="java&#45;keyword">new</span> SshResolver(user:<span class="java&#45;quote">"myuser"</span>, host:<span class="java&#45;quote">"myhost.com"</span>)
sshResolver.addArtifactPattern(
        <span class="java&#45;quote">"/path/to/repo/grails&#45;&#91;artifact&#93;/tags/"</span> +
        <span class="java&#45;quote">"LATEST_RELEASE/grails&#45;&#91;artifact&#93;&#45;&#91;revision&#93;.&#91;ext&#93;"</span>)
sshResolver.latestStrategy =
        <span class="java&#45;keyword">new</span> org.apache.ivy.plugins.latest.LatestTimeStrategy()<p class="paragraph"/>sshResolver.changingPattern = <span class="java&#45;quote">".&#42;SNAPSHOT"</span>
sshResolver.setCheckmodified(<span class="java&#45;keyword">true</span>)</pre></div><p class="paragraph"/>The above example defines an artifact pattern which tells Ivy how to resolve a plugin zip file. For a more detailed explanation on Ivy patterns see the <a href="http://ant.apache.org/ivy/history/2.1.0/concept.html#patterns" target="blank">relevant section</a> in the Ivy user guide.<p class="paragraph"/><h4>Publishing to Maven Compatible Repositories</h4><p class="paragraph"/>In general it is recommended for Grails 1.3 and above to use standard Maven-style repositories to self host plugins. The benefits of doing so include the ability for existing tooling and repository managers to interpret the structure of a Maven repository. In addition Maven compatible repositories are not tied to SVN as Grails repositories are.<p class="paragraph"/>You use the Maven publisher plugin to publish a plugin to a Maven repository. Please refer to the section of the <a href="../guide/single.html#mavendeploy" class="guide">Maven deployment</a> user guide on the subject.<p class="paragraph"/><h4>Publishing to Grails Compatible Repositories</h4><p class="paragraph"/>Specify the <code>grails.plugin.repos.distribution.myRepository</code> setting within the grails-app/conf/BuildConfig.groovy file to publish a Grails plugin to a Grails-compatible repository:<p class="paragraph"/><div class="code"><pre>grails.plugin.repos.distribution.myRepository =
        <span class="java&#45;quote">"https://svn.codehaus.org/grails/trunk/grails&#45;test&#45;plugin&#45;repo"</span></pre></div><p class="paragraph"/>You can also provide this settings in the &#36;USER_HOME/.grails/settings.groovy file if you prefer to share the same settings across multiple projects.<p class="paragraph"/>Once this is done use the <code>repository</code> argument of the <code>release-plugin</code> command to specify the repository to release the plugin into:<p class="paragraph"/><div class="code"><pre>grails release&#45;plugin &#45;repository = myRepository</pre></div>


<a name="12.3 Understanding a Plug-ins Structure"><!-- Legacy link --></a>
<h2 id="understandingPluginStructure">13.3 Understanding a Plugin's Structure</h2>
As as mentioned previously, a plugin is basically a regular Grails application with a plugin descriptor. However when installed, the structure of a plugin differs slightly. For example, take a look at this plugin directory structure:<p class="paragraph"/><div class="code"><pre>+ grails&#45;app
     + controllers
     + domain
     + taglib
     etc.
 + lib
 + src
     + java
     + groovy
 + web&#45;app
     + js
     + css</pre></div><p class="paragraph"/>When a plugin is installed the contents of the <code>grails-app</code> directory will go into a directory such as <code>plugins/example-1.0/grails-app</code>. They <strong class="bold">will not</strong> be copied into the main source tree. A plugin never interferes with a project's primary source tree.<p class="paragraph"/>Dealing with static resources is slightly different. When developing a plugin, just like an application, all static resources go in the <code>web-app</code> directory. You can then link to static resources just like in an application. This example links to a JavaScript source:<p class="paragraph"/><div class="code"><pre><span class="xml&#45;tag">&#60;g:resource dir=<span class="xml&#45;quote">"js"</span> file=<span class="xml&#45;quote">"mycode.js"</span> /&#62;</span></pre></div><p class="paragraph"/>When you run the plugin in development mode the link to the resource will resolve to something like <code>/js/mycode.js</code>. However, when the plugin is installed into an application the path will automatically change to something like <code>/plugin/example-0.1/js/mycode.js</code> and Grails will deal with making sure the resources are in the right place.<p class="paragraph"/>There is a special <code>pluginContextPath</code> variable that can be used whilst both developing the plugin and when in the plugin is installed into the application to find out what the correct path to the plugin is.<p class="paragraph"/>At runtime the <code>pluginContextPath</code> variable will either evaluate to an empty string or <code>/plugins/example</code> depending on whether the plugin is running standalone or has been installed in an application<p class="paragraph"/>Java and Groovy code that the plugin provides within the lib and <code>src/java</code> and <code>src/groovy</code> directories will be compiled into the main project's <code>web-app/WEB-INF/classes</code> directory so that they are made available at runtime.


<a name="12.4 Providing Basic Artefacts"><!-- Legacy link --></a>
<h2 id="providingBasicArtefacts">13.4 Providing Basic Artefacts</h2>
<h4>Adding a new Script</h4><p class="paragraph"/>A plugin can add a new script simply by providing the relevant Gant script in its scripts directory:<p class="paragraph"/><div class="code"><pre>+ MyPlugin.groovy
   + scripts     &#60;&#45;&#45; additional scripts here
   + grails&#45;app
        + controllers
        + services
        + etc.
    + lib</pre></div><p class="paragraph"/><h4>Adding a new grails-app artifact (Controller, Tag Library, Service, etc.)</h4><p class="paragraph"/>A plugin can add new artifacts by creating the relevant file within the <code>grails-app</code> tree. Note that the plugin is loaded from where it is installed and not copied into the main application tree.<p class="paragraph"/><div class="code"><pre>+ ExamplePlugin.groovy
   + scripts
   + grails&#45;app
        + controllers  &#60;&#45;&#45; additional controllers here
        + services &#60;&#45;&#45; additional services here
        + etc.  &#60;&#45;&#45; additional XXX here
    + lib</pre></div><p class="paragraph"/><h4>Providing Views, Templates and View resolution</h4><p class="paragraph"/>When a plugin provides a controller it may also provide default views to be rendered. This is an excellent way to modularize your application through plugins. Grails' view resolution mechanism will first look for the view in the application it is installed into and if that fails will attempt to look for the view within the plugin. This means that you can override views provided by a plugin by creating corresponding GSPs in the application's <code>grails-app/views</code> directory.<p class="paragraph"/>For example, consider a controller called <code>BookController</code> that's provided by an 'amazon' plugin. If the action being executed is <code>list</code>, Grails will first look for a view called <code>grails-app/views/book/list.gsp</code> then if that fails it will look for the same view relative to the plugin.<p class="paragraph"/>However if the view uses templates that are also provided by the plugin then the following syntax may be necessary:<p class="paragraph"/><div class="code"><pre>&#60;g:render template=<span class="java&#45;quote">"fooTemplate"</span> plugin=<span class="java&#45;quote">"amazon"</span>/&#62;</pre></div><p class="paragraph"/>Note the usage of the <code>plugin</code> attribute, which contains the name of the plugin where the template resides. If this is not specified then Grails will look for the template relative to the application.<p class="paragraph"/><h4>Excluded Artefacts</h4><p class="paragraph"/>By default Grails excludes the following files during the packaging process:
<ul class="star">
<li><code>grails-app/conf/BootStrap.groovy</code></li>
<li><code>grails-app/conf/BuildConfig.groovy</code> (although it is used to generate <code>dependencies.groovy</code>)</li>
<li><code>grails-app/conf/Config.groovy</code></li>
<li><code>grails-app/conf/DataSource.groovy</code> (and any other <code>*DataSource.groovy</code>)</li>
<li><code>grails-app/conf/UrlMappings.groovy</code></li>
<li><code>grails-app/conf/spring/resources.groovy</code></li>
<li>Everything within <code>/web-app/WEB-INF</code></li>
<li>Everything within <code>/web-app/plugins/&#42;&#42;</code></li>
<li>Everything within <code>/test/&#42;&#42;</code></li>
<li>SCM management files within <code>&#42;&#42;/.svn/&#42;&#42;</code> and <code>&#42;&#42;/CVS/&#42;&#42;</code></li>
</ul><p class="paragraph"/>If your plugin requires files under the <code>web-app/WEB-INF</code> directory it is recommended that you modify the plugin's <code>scripts/_Install.groovy</code> Gant script to install these artefacts into the target project's directory tree.<p class="paragraph"/>In addition, the default <code>UrlMappings.groovy</code> file is excluded to avoid naming conflicts, however you are free to add a UrlMappings definition under a different name which <strong class="bold">will</strong> be included. For example a file called <code>grails-app/conf/BlogUrlMappings.groovy</code> is fine.<p class="paragraph"/>The list of excludes is extensible with the <code>pluginExcludes</code> property:<p class="paragraph"/><div class="code"><pre>// resources that are excluded from plugin packaging
def pluginExcludes = &#91;
    <span class="java&#45;quote">"grails&#45;app/views/error.gsp"</span>
&#93;</pre></div><p class="paragraph"/>This is useful for example to include demo or test resources in the plugin repository, but not include them in the final distribution.


<a name="12.5 Evaluating Conventions"><!-- Legacy link --></a>
<h2 id="evaluatingConventions">13.5 Evaluating Conventions</h2>
Before looking at providing runtime configuration based on conventions you first need to understand how to evaluate those conventions from a plugin. Every plugin has an implicit <code>application</code> variable which is an instance of the <a href="../api/org/codehaus/groovy/grails/commons/GrailsApplication.html" class="api">GrailsApplication</a> interface.<p class="paragraph"/>The <code>GrailsApplication</code> interface provides methods to evaluate the conventions within the project and internally stores references to all artifact classes within your application.<p class="paragraph"/>Artifacts implement the <a href="../api/org/codehaus/groovy/grails/commons/GrailsClass.html" class="api">GrailsClass</a> interface, which represents a Grails resource such as a controller or a tag library. For example to get all <code>GrailsClass</code> instances you can do:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">for</span> (grailsClass in application.allClasses) &#123;
    println grailsClass.name
&#125;</pre></div><p class="paragraph"/><code>GrailsApplication</code> has a few "magic" properties to narrow the type of artefact you are interested in. For example to access controllers you can use:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">for</span> (controllerClass in application.controllerClasses) &#123;
    println controllerClass.name
&#125;</pre></div><p class="paragraph"/>The dynamic method conventions are as follows:
<ul class="star">
<li><code>*Classes</code> - Retrieves all the classes for a particular artefact name. For example <code>application.controllerClasses</code>.</li>
<li><code>get*Class</code> - Retrieves a named class for a particular artefact. For example <code>application.getControllerClass("PersonController")</code></li>
<li><code>is*Class</code> - Returns <code>true</code> if the given class is of the given artefact type. For example <code>application.isControllerClass(PersonController)</code></li>
</ul><p class="paragraph"/>The <code>GrailsClass</code> interface has a number of useful methods that let you further evaluate and work with the conventions. These include:
<ul class="star">
<li><code>getPropertyValue</code> - Gets the initial value of the given property on the class</li>
<li><code>hasProperty</code> - Returns <code>true</code> if the class has the specified property</li>
<li><code>newInstance</code> - Creates a new instance of this class.</li>
<li><code>getName</code> -  Returns the logical name of the class in the application without the trailing convention part if applicable</li>
<li><code>getShortName</code> - Returns the short name of the class without package prefix</li>
<li><code>getFullName</code> - Returns the full name of the class in the application with the trailing convention part and with the package name</li>
<li><code>getPropertyName</code> - Returns the name of the class as a property name</li>
<li><code>getLogicalPropertyName</code> - Returns the logical property name of the class in the application without the trailing convention part if applicable</li>
<li><code>getNaturalName</code> - Returns the name of the property in natural terms (eg. 'lastName' becomes 'Last Name')</li>
<li><code>getPackageName</code> - Returns the package name</li>
</ul><p class="paragraph"/>For a full reference refer to the <a href="../api/org/codehaus/groovy/grails/commons/GrailsClass.html" class="api">javadoc API</a>.


<a name="12.6 Hooking into Build Events"><!-- Legacy link --></a>
<h2 id="hookingIntoBuildEvents">13.6 Hooking into Build Events</h2>
<h4>Post-Install Configuration and Participating in Upgrades</h4><p class="paragraph"/>Grails plugins can do post-install configuration and participate in application upgrade process (the <a href="../ref/Command Line/upgrade.html" class="commandLine">upgrade</a> command). This is achieved using two specially named scripts under the <code>scripts</code> directory of the plugin - <code>_Install.groovy</code> and <code>_Upgrade.groovy</code>.<p class="paragraph"/><code>_Install.groovy</code> is executed after the plugin has been installed and <code>_Upgrade.groovy</code> is executed each time the user upgrades the application (but not the plugin) with <a href="../ref/Command Line/upgrade.html" class="commandLine">upgrade</a> command.<p class="paragraph"/>These scripts are <a href="../guide/single.html#commandLine" class="guide">Gant</a> scripts, so you can use the full power of Gant. An addition to the standard Gant variables there is also a <code>pluginBasedir</code> variable which points at the plugin installation basedir.<p class="paragraph"/>As an example this <code>_Install.groovy</code> script will create a new directory type under the <code>grails-app</code> directory and install a configuration template:<p class="paragraph"/><div class="code"><pre>ant.mkdir(dir: <span class="java&#45;quote">"$&#123;basedir&#125;/grails&#45;app/jobs"</span>)<p class="paragraph"/>ant.copy(file: <span class="java&#45;quote">"$&#123;pluginBasedir&#125;/src/samples/SamplePluginConfig.groovy"</span>,
         todir: <span class="java&#45;quote">"$&#123;basedir&#125;/grails&#45;app/conf"</span>)</pre></div><p class="paragraph"/>The <code>pluginBasedir</code> variable is not available in custom scripts, but you can use <code>fooPluginDir</code>, where <code>foo</code> is the name of your plugin.<p class="paragraph"/><h4>Scripting events</h4><p class="paragraph"/>It is also possible to hook into command line scripting events. These are events triggered during execution of Grails target and plugin scripts.<p class="paragraph"/>For example, you can hook into status update output (i.e. "Tests passed", "Server running") and the creation of files or artefacts.<p class="paragraph"/>A plugin just has to provide an <code>_Events.groovy</code> script to listen to the required events. Refer the documentation on <a href="../guide/single.html#events" class="guide">Hooking into Events</a> for further information.


<a name="12.7 Hooking into Runtime Configuration"><!-- Legacy link --></a>
<h2 id="hookingIntoRuntimeConfiguration">13.7 Hooking into Runtime Configuration</h2>
Grails provides a number of hooks to leverage the different parts of the system and perform runtime configuration by convention.<p class="paragraph"/><h4>Hooking into the Grails Spring configuration</h4><p class="paragraph"/>First, you can hook in Grails runtime configuration by providing a property called <code>doWithSpring</code> which is assigned a block of code. For example the following snippet is from one of the core Grails plugins that provides <a href="../guide/single.html#i18n" class="guide">i18n</a> support:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">import</span> org.springframework.web.servlet.i18n.CookieLocaleResolver
<span class="java&#45;keyword">import</span> org.springframework.web.servlet.i18n.LocaleChangeInterceptor
<span class="java&#45;keyword">import</span> org.springframework.context.support.ReloadableResourceBundleMessageSource<p class="paragraph"/>class I18nGrailsPlugin &#123;<p class="paragraph"/>    def version = <span class="java&#45;quote">"0.1"</span><p class="paragraph"/>    def doWithSpring = &#123;
        messageSource(ReloadableResourceBundleMessageSource) &#123;
            basename = <span class="java&#45;quote">"WEB&#45;INF/grails&#45;app/i18n/messages"</span>
        &#125;
        localeChangeInterceptor(LocaleChangeInterceptor) &#123;
            paramName = <span class="java&#45;quote">"lang"</span>
        &#125;
        localeResolver(CookieLocaleResolver)
    &#125;
&#125;</pre></div><p class="paragraph"/>This plugin configures the Grails <code>messageSource</code> bean and a couple of other beans to manage Locale resolution and switching. It using the <a href="../guide/single.html#spring" class="guide">Spring Bean Builder</a> syntax to do so.<p class="paragraph"/><h4>Participating in web.xml Generation</h4><p class="paragraph"/>Grails generates the <code>WEB-INF/web.xml</code> file at load time, and although plugins cannot change this file directly, they can participate in the generation of the file. A plugin can provide a <code>doWithWebDescriptor</code> property that is assigned a block of code that gets passed the <code>web.xml</code> as an <code>XmlSlurper</code> <code>GPathResult</code>.<p class="paragraph"/><h5>Add <code>servlet</code> and <code>servlet-mapping</code></h5><p class="paragraph"/>Consider this example from the <code>ControllersPlugin</code>:<p class="paragraph"/><div class="code"><pre>def doWithWebDescriptor = &#123; webXml &#45;&#62;<p class="paragraph"/>    def mappingElement = webXml.'servlet&#45;mapping'<p class="paragraph"/>    def lastMapping = mappingElement&#91;mappingElement.size() &#45; 1&#93;
    lastMapping + &#123;
        'servlet&#45;mapping' &#123;
            'servlet&#45;name'(<span class="java&#45;quote">"grails"</span>)
            'url&#45;pattern'(<span class="java&#45;quote">"&#42;.dispatch"</span>)
        &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/>Here the plugin gets a reference to the last <code>&#60;servlet-mapping&#62;</code> element and appends Grails' servlet after it using XmlSlurper's ability to programmatically modify XML using closures and blocks.<p class="paragraph"/><h5>Add <code>filter</code> and <code>filter-mapping</code></h5><p class="paragraph"/>Adding a filter with its mapping works a little differently. The location of the <code>&#60;filter&#62;</code> element doesn't matter since order is not important, so it's simplest to insert your custom filter definition immediately after the last <code>&#60;context-param&#62;</code> element. Order  <em class="italic">is</em>  important for mappings, but the usual approach is to add it immediately after the last <code>&#60;filter&#62;</code> element like so:<p class="paragraph"/><div class="code"><pre>def doWithWebDescriptor = &#123; webXml &#45;&#62;<p class="paragraph"/>    def contextParam = webXml.'context&#45;param'<p class="paragraph"/>    contextParam&#91;contextParam.size() &#45; 1&#93; + &#123;
        'filter' &#123;
            'filter&#45;name'('springSecurityFilterChain')
            'filter&#45;class'(DelegatingFilterProxy.name)
        &#125;
    &#125;<p class="paragraph"/>    def filter = webXml.'filter'
    filter&#91;filter.size() &#45; 1&#93; + &#123;
        'filter&#45;mapping'&#123;
            'filter&#45;name'('springSecurityFilterChain')
            'url&#45;pattern'('/&#42;')
        &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/>In some cases you need to ensure that your filter comes after one of the standard Grails filters, such as the Spring character encoding filter or the SiteMesh filter. Fortunately you can insert filter mappings immediately after the standard ones (more accurately, any that are in the template web.xml file) like so:<p class="paragraph"/><div class="code"><pre>def doWithWebDescriptor = &#123; webXml &#45;&#62;
    ...<p class="paragraph"/>    // Insert the Spring Security filter after the Spring
    // character encoding filter.
    def filter = webXml.'filter&#45;mapping'.find &#123;
        it.'filter&#45;name'.text() == <span class="java&#45;quote">"charEncodingFilter"</span>
    &#125;<p class="paragraph"/>    filter + &#123;
        'filter&#45;mapping'&#123;
            'filter&#45;name'('springSecurityFilterChain')
            'url&#45;pattern'('/&#42;')
        &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/><h4>Doing Post Initialisation Configuration</h4><p class="paragraph"/>Sometimes it is useful to be able do some runtime configuration after the Spring <a href="http://static.springsource.org/spring/docs/3.0.x/javadoc-api/org/springframework/context/ApplicationContext.html" class="api">ApplicationContext</a> has been built. In this case you can define a <code>doWithApplicationContext</code> closure property.<p class="paragraph"/><div class="code"><pre>class SimplePlugin &#123;<p class="paragraph"/>    def name = <span class="java&#45;quote">"simple"</span>
    def version = <span class="java&#45;quote">"1.1"</span><p class="paragraph"/>    def doWithApplicationContext = &#123; appCtx &#45;&#62;
        def sessionFactory = appCtx.sessionFactory
        // <span class="java&#45;keyword">do</span> something here with session factory
    &#125;
&#125;</pre></div>


<a name="12.8 Adding Dynamic Methods at Runtime"><!-- Legacy link --></a>
<h2 id="addingDynamicMethodsAtRuntime">13.8 Adding Dynamic Methods at Runtime</h2>
<h4>The Basics</h4><p class="paragraph"/>Grails plugins let you register dynamic methods with any Grails-managed or other class at runtime. This work is done in a <code>doWithDynamicMethods</code> closure.<p class="paragraph"/>For Grails-managed classes like controllers, tag libraries and so forth you can add methods, constructors etc. using the <a href="http://groovy.codehaus.org/ExpandoMetaClass" target="blank">ExpandoMetaClass</a> mechanism by accessing each controller's <a href="http://groovy.codehaus.org/api/groovy/lang/MetaClass.html" class="api">MetaClass</a>:<p class="paragraph"/><div class="code"><pre>class ExamplePlugin &#123;
    def doWithDynamicMethods = &#123; applicationContext &#45;&#62;
        <span class="java&#45;keyword">for</span> (controllerClass in application.controllerClasses) &#123;
             controllerClass.metaClass.myNewMethod = &#123;&#45;&#62; println <span class="java&#45;quote">"hello world"</span> &#125;
        &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/>In this case we use the implicit application object to get a reference to all of the controller classes' MetaClass instances and add a new method called <code>myNewMethod</code> to each controller. If you know beforehand the class you wish the add a method to you can simply reference its <code>metaClass</code> property.<p class="paragraph"/>For example we can add a new method <code>swapCase</code> to <code>java.lang.String</code>:<p class="paragraph"/><div class="code"><pre>class ExamplePlugin &#123;<p class="paragraph"/>    def doWithDynamicMethods = &#123; applicationContext &#45;&#62;
        <span class="java&#45;object">String</span>.metaClass.swapCase = &#123;&#45;&#62;
             def sb = <span class="java&#45;keyword">new</span> StringBuilder()
             delegate.each &#123;
                 sb &#60;&#60; (<span class="java&#45;object">Character</span>.isUpperCase(it as <span class="java&#45;object">char</span>) ?
                        <span class="java&#45;object">Character</span>.toLowerCase(it as <span class="java&#45;object">char</span>) :
                        <span class="java&#45;object">Character</span>.toUpperCase(it as <span class="java&#45;object">char</span>))
             &#125;
             sb.toString()
        &#125;<p class="paragraph"/>        assert <span class="java&#45;quote">"UpAndDown"</span> == <span class="java&#45;quote">"uPaNDdOWN"</span>.swapCase()
    &#125;
&#125;</pre></div><p class="paragraph"/><h4>Interacting with the ApplicationContext</h4><p class="paragraph"/>The <code>doWithDynamicMethods</code> closure gets passed the Spring <code>ApplicationContext</code> instance. This is useful as it lets you interact with objects within it. For example if you were implementing a method to interact with Hibernate you could use the <code>SessionFactory</code> instance in combination with a <code>HibernateTemplate</code>:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">import</span> org.springframework.orm.hibernate3.HibernateTemplate<p class="paragraph"/>class ExampleHibernatePlugin &#123;<p class="paragraph"/>   def doWithDynamicMethods = &#123; applicationContext &#45;&#62;<p class="paragraph"/>       <span class="java&#45;keyword">for</span> (domainClass in application.domainClasses) &#123;<p class="paragraph"/>           domainClass.metaClass.<span class="java&#45;keyword">static</span>.load = &#123; <span class="java&#45;object">Long</span> id&#45;&#62;
                def sf = applicationContext.sessionFactory
                def template = <span class="java&#45;keyword">new</span> HibernateTemplate(sf)
                template.load(delegate, id)
           &#125;
       &#125;
   &#125;
&#125;</pre></div><p class="paragraph"/>Also because of the autowiring and dependency injection capability of the Spring container you can implement more powerful dynamic constructors that use the application context to wire dependencies into your object at runtime:<p class="paragraph"/><div class="code"><pre>class MyConstructorPlugin &#123;<p class="paragraph"/>    def doWithDynamicMethods = &#123; applicationContext &#45;&#62;
         <span class="java&#45;keyword">for</span> (domainClass in application.domainClasses) &#123;
              domainClass.metaClass.constructor = &#123;&#45;&#62;
                  <span class="java&#45;keyword">return</span> applicationContext.getBean(domainClass.name)
              &#125;
         &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/>Here we actually replace the default constructor with one that looks up prototyped Spring beans instead!


<a name="12.9 Participating in Auto Reload Events"><!-- Legacy link --></a>
<h2 id="participatingInAutoReloadEvents">13.9 Participating in Auto Reload Events</h2>
<h4>Monitoring Resources for Changes</h4><p class="paragraph"/>Often it is valuable to monitor resources for changes and perform some action when they occur. This is how Grails implements advanced reloading of application state at runtime. For example, consider this simplified snippet from the Grails <code>ServicesPlugin</code>:<p class="paragraph"/><div class="code"><pre>class ServicesGrailsPlugin &#123;
    &#8230;
    def watchedResources = <span class="java&#45;quote">"file:./grails&#45;app/services/&#42;Service.groovy"</span><p class="paragraph"/>    &#8230;
    def onChange = &#123; event &#45;&#62;
        <span class="java&#45;keyword">if</span> (event.source) &#123;
            def serviceClass = application.addServiceClass(event.source)
            def serviceName = <span class="java&#45;quote">"&#36;&#123;serviceClass.propertyName&#125;"</span>
            def beans = beans &#123;
                <span class="java&#45;quote">"$serviceName"</span>(serviceClass.getClazz()) &#123; bean &#45;&#62;
                    bean.autowire =  <span class="java&#45;keyword">true</span>
                &#125;
            &#125;
            <span class="java&#45;keyword">if</span> (event.ctx) &#123;
                event.ctx.registerBeanDefinition(
                        serviceName,
                        beans.getBeanDefinition(serviceName))
            &#125;
        &#125;
    &#125;
&#125;</pre></div><p class="paragraph"/>First it defines <code>watchedResources</code> as either a String or a List of strings that contain either the references or patterns of the resources to watch. If the watched resources specify a Groovy file, when it is changed it will automatically be reloaded and passed into the <code>onChange</code> closure in the <code>event</code> object.<p class="paragraph"/>The <code>event</code> object defines a number of useful properties:
<ul class="star">
<li><code>event.source</code> - The source of the event, either the reloaded <code>Class</code> or a Spring <code>Resource</code></li>
<li><code>event.ctx</code> - The Spring <code>ApplicationContext</code> instance</li>
<li><code>event.plugin</code> - The plugin object that manages the resource (usually <code>this</code>)</li>
<li><code>event.application</code> - The <code>GrailsApplication</code> instance</li>
<li><code>event.manager</code> - The <code>GrailsPluginManager</code> instance</li>
</ul><p class="paragraph"/>These objects are available to help you apply the appropriate changes based on what changed. In the "Services" example above, a new service bean is re-registered with the <code>ApplicationContext</code> when one of the service classes changes.<p class="paragraph"/><h4>Influencing Other Plugins</h4><p class="paragraph"/>In addition to reacting to changes, sometimes a plugin needs to "influence" another.<p class="paragraph"/>Take for example the Services and Controllers plugins. When a service is reloaded, unless you reload the controllers too, problems will occur when you try to auto-wire the reloaded service into an older controller Class.<p class="paragraph"/>To get around this, you can specify which plugins another plugin "influences". This means that when one plugin detects a change, it will reload itself and then reload its influenced plugins. For example consider this snippet from the <code>ServicesGrailsPlugin</code>:<p class="paragraph"/><div class="code"><pre>def influences = &#91;'controllers'&#93;</pre></div><p class="paragraph"/><h4>Observing other plugins</h4><p class="paragraph"/>If there is a particular plugin that you would like to observe for changes but not necessary watch the resources that it monitors you can use the "observe" property:<p class="paragraph"/><div class="code"><pre>def observe = &#91;<span class="java&#45;quote">"controllers"</span>&#93;</pre></div><p class="paragraph"/>In this case when a controller is changed you will also receive the event chained from the controllers plugin.<p class="paragraph"/>It is also possible for a plugin to observe all loaded plugins by using a wildcard:<p class="paragraph"/><div class="code"><pre>def observe = &#91;<span class="java&#45;quote">"&#42;"</span>&#93;</pre></div><p class="paragraph"/>The Logging plugin does exactly this so that it can add the <code>log</code> property back to  <em class="italic">any</em>  artefact that changes while the application is running.


<a name="12.10 Understanding Plug-in Load Order"><!-- Legacy link --></a>
<h2 id="understandingPluginLoadOrder">13.10 Understanding Plugin Load Order</h2>
<h4>Controlling Plugin Dependencies</h4><p class="paragraph"/>Plugins often depend on the presence of other plugins and can adapt depending on the presence of others. This is implemented with two properties. The first is called <code>dependsOn</code>. For example, take a look at this snippet from the Hibernate plugin:<p class="paragraph"/><div class="code"><pre>class HibernateGrailsPlugin &#123;<p class="paragraph"/>    def version = <span class="java&#45;quote">"1.0"</span><p class="paragraph"/>    def dependsOn = &#91;dataSource: <span class="java&#45;quote">"1.0"</span>,
                     domainClass: <span class="java&#45;quote">"1.0"</span>,
                     i18n: <span class="java&#45;quote">"1.0"</span>,
                     core: <span class="java&#45;quote">"1.0"</span>&#93;
&#125;</pre></div><p class="paragraph"/>The Hibernate plugin is dependent on the presence of four plugins: the <code>dataSource</code>, <code>domainClass</code>, <code>i18n</code> and <code>core</code> plugins.<p class="paragraph"/>The dependencies will be loaded before the Hibernate plugin and if all dependencies do not load, then the plugin will not load.<p class="paragraph"/>The <code>dependsOn</code> property also supports a mini expression language for specifying version ranges. A few examples of the syntax can be seen below:<p class="paragraph"/><div class="code"><pre>def dependsOn = &#91;foo: <span class="java&#45;quote">"&#42; &#62; 1.0"</span>&#93;
def dependsOn = &#91;foo: <span class="java&#45;quote">"1.0 &#62; 1.1"</span>&#93;
def dependsOn = &#91;foo: <span class="java&#45;quote">"1.0 &#62; &#42;"</span>&#93;</pre></div><p class="paragraph"/>When the wildcard * character is used it denotes "any" version. The expression syntax also excludes any suffixes such as -BETA, -ALPHA etc. so for example the expression "1.0 &#62; 1.1" would match any of the following versions:
<ul class="star">
<li>1.1</li>
<li>1.0</li>
<li>1.0.1</li>
<li>1.0.3-SNAPSHOT</li>
<li>1.1-BETA2</li>
</ul><p class="paragraph"/><h4>Controlling Load Order</h4><p class="paragraph"/>Using <code>dependsOn</code> establishes a "hard" dependency in that if the dependency is not resolved, the plugin will give up and won't load.  It is possible though to have a weaker dependency using the <code>loadAfter</code> and <code>loadBefore</code> properties:<p class="paragraph"/><div class="code"><pre>def loadAfter = &#91;'controllers'&#93;</pre></div><p class="paragraph"/>Here the plugin will be loaded after the <code>controllers</code> plugin if it exists, otherwise it will just be loaded. The plugin can then adapt to the presence of the other plugin, for example the Hibernate plugin has this code in its <code>doWithSpring</code> closure:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">if</span> (manager?.hasGrailsPlugin(<span class="java&#45;quote">"controllers"</span>)) &#123;
    openSessionInViewInterceptor(OpenSessionInViewInterceptor) &#123;
        flushMode = HibernateAccessor.FLUSH_MANUAL
        sessionFactory = sessionFactory
    &#125;
    grailsUrlHandlerMapping.interceptors &#60;&#60; openSessionInViewInterceptor
&#125;</pre></div><p class="paragraph"/>Here the Hibernate plugin will only register an <code>OpenSessionInViewInterceptor</code> if the <code>controllers</code> plugin has been loaded. The <code>manager</code> variable is an instance of the <a href="../api/org/codehaus/groovy/grails/plugins/GrailsPluginManager.html" class="api">GrailsPluginManager</a> interface and it provides methods to interact with other plugins.<p class="paragraph"/>You can also use the <code>loadBefore</code> property to specify one or more plugins that your plugin should load before:<p class="paragraph"/><div class="code"><pre>def loadBefore = &#91;'rabbitmq'&#93;</pre></div><p class="paragraph"/><h4>Scopes and Environments</h4><p class="paragraph"/>It's not only plugin load order that you can control. You can also specify which environments your plugin should be loaded in and which scopes (stages of a build). Simply declare one or both of these properties in your plugin descriptor:<p class="paragraph"/><div class="code"><pre>def environments = &#91;'development', 'test', 'myCustomEnv'&#93;
def scopes = &#91;excludes:'war'&#93;</pre></div><p class="paragraph"/>In this example, the plugin will only load in the 'development' and 'test' environments. Nor will it be packaged into the WAR file, because it's excluded from the 'war' phase. This allows <code>development-only</code> plugins to not be packaged for production use.<p class="paragraph"/>The full list of available scopes are defined by the enum <a href="../api/grails/util/BuildScope.html" class="api">BuildScope</a>, but here's a summary:
<ul class="star">
<li><code>test</code> - when running tests</li>
<li><code>functional-test</code> - when running functional tests</li>
<li><code>run</code> - for run-app and run-war</li>
<li><code>war</code> - when packaging the application as a WAR file</li>
<li><code>all</code> - plugin applies to all scopes (default)</li>
</ul><p class="paragraph"/>Both properties can be one of:
<ul class="star">
<li>a string - a sole inclusion</li>
<li>a list - a list of environments or scopes to include</li>
<li>a map - for full control, with 'includes' and/or 'excludes' keys that can have string or list values</li>
</ul><p class="paragraph"/>For example,<p class="paragraph"/><div class="code"><pre>def environments = <span class="java&#45;quote">"test"</span></pre></div><p class="paragraph"/>will only include the plugin in the test environment, whereas<p class="paragraph"/><div class="code"><pre>def environments = &#91;<span class="java&#45;quote">"development"</span>, <span class="java&#45;quote">"test"</span>&#93;</pre></div><p class="paragraph"/>will include it in both the development  <em class="italic">and</em>  test environments. Finally,<p class="paragraph"/><div class="code"><pre>def environments = &#91;includes: &#91;<span class="java&#45;quote">"development"</span>, <span class="java&#45;quote">"test"</span>&#93;&#93;</pre></div><p class="paragraph"/>will do the same thing.



<h2 id="artefactApi">13.11 The Artefact API</h2>
You should by now understand that Grails has the concept of artefacts: special types of classes that it knows about and can treat differently from normal Groovy and Java classes, for example by enhancing them with extra properties and methods. Examples of artefacts include domain classes and controllers. What you may not be aware of is that Grails allows application and plugin developers access to the underlying infrastructure for artefacts, which means you can find out what artefacts are available and even enhance them yourself. You can even provide your own custom artefact types.



<h2 id="queryingArtefacts">13.11.1 Asking About Available Artefacts</h2>
As a plugin developer, it can be important for you to find out about what domain classes, controllers, or other types of artefact are available in an application. For example, the <a href="http://grails.org/plugin/searchable" target="blank">Searchable plugin</a> needs to know what domain classes exist so it can check them for any <code>searchable</code> properties and index the appropriate ones. So how does it do it? The answer lies with the <code>grailsApplication</code> object, and instance of <a href="../api/org/codehaus/groovy/grails/commons/GrailsApplication.html" class="api">GrailsApplication</a> that's available automatically in controllers and GSPs and can be <a href="../guide/single.html#dependencyInjectionServices" class="guide">injected</a> everywhere else.<p class="paragraph"/>The <code>grailsApplication</code> object has several important properties and methods for querying artefacts. Probably the most common is the one that gives you all the classes of a particular artefact type:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">for</span> (cls in grailsApplication.&#60;artefactType&#62;Classes) &#123;
    &#8230;
&#125;</pre></div><p class="paragraph"/>In this case, <code>artefactType</code> is the property name form of the artefact type. With core Grails you have:
<ul class="star">
<li>domain</li>
<li>controller</li>
<li>tagLib</li>
<li>service</li>
<li>codec</li>
<li>bootstrap</li>
<li>urlMappings</li>
</ul><p class="paragraph"/>So for example, if you want to iterate over all the domain classes, you use:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">for</span> (cls in grailsApplication.domainClasses) &#123;
    &#8230;
&#125;</pre></div><p class="paragraph"/>and for URL mappings:<p class="paragraph"/><div class="code"><pre><span class="java&#45;keyword">for</span> (cls in grailsApplication.urlMappingsClasses) &#123;
    &#8230;
&#125;</pre></div><p class="paragraph"/>You need to be aware that the objects returned by these properties are not instances of <a href="http://download.oracle.com/javase/1.5.0/docs/api/java/lang/Class.html" class="api">Class</a>. Instead, they are instances of <a href="../api/org/codehaus/groovy/grails/commons/GrailsClass.html" class="api">GrailsClass</a> that has some particularly useful properties and methods, including one for the underlying <code>Class</code>:
<ul class="star">
<li><code>shortName</code> - the class name of the artefact without the package (equivalent of <code>Class.simpleName</code>).</li>
<li><code>logicalPropertyName</code> - the artefact name in property form without the 'type' suffix. So <code>MyGreatController</code> becomes 'myGreat'.</li>
<li><code>isAbstract()</code> - a boolean indicating whether the artefact class is abstract or not.</li>
<li><code>getPropertyValue(name)</code> - returns the value of the given property, whether it's a static or an instance one. This works best if the property is initialised on declaration, e.g. <code>static transactional = true</code>.</li>
</ul><p class="paragraph"/>The artefact API also allows you to fetch classes by name and check whether a class is an artefact:
<ul class="star">
<li>get&#60;type&#62;Class(String name)</li>
<li>is&#60;type&#62;Class(Class clazz)</li>
</ul><p class="paragraph"/>The first method will retrieve the <code>GrailsClass</code> instance for the given name, e.g. 'MyGreatController'. The second will check whether a class is a particular type of artefact. For example, you can use <code>grailsApplication.isControllerClass(org.example.MyGreatController)</code> to check whether <code>MyGreatController</code> is in fact a controller.



<h2 id="customArtefacts">13.11.2 Adding Your Own Artefact Types</h2>
Plugins can easily provide their own artefacts so that they can easily find out what implementations are available and take part in reloading. All you need to do is create an <code>ArtefactHandler</code> implementation and register it in your main plugin class:<p class="paragraph"/><div class="code"><pre>class MyGrailsPlugin &#123;
    def artefacts = &#91; org.somewhere.MyArtefactHandler &#93;
    &#8230;
&#125;</pre></div><p class="paragraph"/>The <code>artefacts</code> list can contain either handler classes (as above) or instances of handlers.<p class="paragraph"/>So, what does an artefact handler look like? Well, put simply it is an implementation of the <a href="../api/org/codehaus/groovy/grails/commons/ArtefactHandler.html" class="api">ArtefactHandler</a> interface. To make life a bit easier, there is a skeleton implementation that can readily be extended: <a href="../api/org/codehaus/groovy/grails/commons/ArtefactHandlerAdapter.html" class="api">ArtefactHandlerAdapter</a>.<p class="paragraph"/>In addition to the handler itself, every new artefact needs a corresponding wrapper class that implements <a href="../api/org/codehaus/groovy/grails/commons/GrailsClass.html" class="api">GrailsClass</a>. Again, skeleton implementations are available such as <a href="../api/org/codehaus/groovy/grails/commons/AbstractInjectableGrailsClass.html" class="api">AbstractInjectableGrailsClass</a>, which is particularly useful as it turns your artefact into a Spring bean that is auto-wired, just like controllers and services.<p class="paragraph"/>The best way to understand how both the handler and wrapper classes work is to look at the Quartz plugin:
<ul class="star">
<li><a href="http://github.com/nebolsin/grails-quartz/blob/master/src/java/grails/plugins/quartz/GrailsJobClass.java" target="blank">GrailsJobClass</a></li>
<li><a href="http://github.com/nebolsin/grails-quartz/blob/master/src/java/grails/plugins/quartz/DefaultGrailsJobClass.java" target="blank">DefaultGrailsJobClass</a></li>
<li><a href="http://github.com/nebolsin/grails-quartz/blob/master/src/java/grails/plugins/quartz/JobArtefactHandler.java" target="blank">JobArtefactHandler</a></li>
</ul><p class="paragraph"/>Another example is the <a href="http://github.com/pledbrook/grails-shiro" target="blank">Shiro plugin</a> which adds a realm artefact.


<a name="12.11 Binary Plugins"><!-- Legacy link --></a>
<h2 id="binaryPlugins">13.12 Binary Plugins</h2>
Regular Grails plugins are packaged as zip files containing the full source of the plugin. This has some advantages in terms of being an open distribution system (anyone can see the source), in addition to avoiding problems with the source compatibility level used for compilation.<p class="paragraph"/>As of Grails 2.0 you can pre-compile Grails plugins into regular JAR files known as "binary plugins". This has several advantages (and some disadvantages as discussed in the advantages of source plugins above) including:
<ul class="star">
<li>Binary plugins can be published as standard JAR files to a Maven repository</li>
<li>Binary plugins can be declared like any other JAR dependency</li>
<li>Commercial plugins are more viable since the source isn't published</li>
<li>IDEs have a better understanding since binary plugins are regular JAR files containing classes</li>
</ul><p class="paragraph"/><h4>Packaging</h4><p class="paragraph"/>To package a plugin in binary form you can use the package-plugin command and the <code>--binary</code> flag:<p class="paragraph"/><div class="code"><pre>grails <span class="java&#45;keyword">package</span>&#45;plugin &#45;&#45;binary</pre></div><p class="paragraph"/>Supported artefacts include:
<ul class="star">
<li>Grails artifact classes such as controllers, domain classes and so on</li>
<li>I18n Message bundles</li>
<li>GSP Views, layouts and templates</li>
</ul><p class="paragraph"/>You can also specify the packaging in the plugin descriptor:<p class="paragraph"/><div class="code"><pre>def packaging = <span class="java&#45;quote">"binary"</span></pre></div><p class="paragraph"/>in which case the packaging will default to binary.<p class="paragraph"/><h4>Using Binary Plugins</h4><p class="paragraph"/>The packaging process creates a JAR file in the <code>target</code> directory of the plugin, for example <code>target/foo-plugin-0.1.jar</code>. There are two ways to incorporate a binary plugin into an application.<p class="paragraph"/>One is simply placing the plugin JAR file in your application's <code>lib</code> directory. The other is to publish the plugin JAR to a compatible Maven repository and declare it as a dependency in <code>grails-app/conf/BuildConfig.groovy</code>:<p class="paragraph"/><div class="code"><pre>dependencies &#123;
    compile <span class="java&#45;quote">"mycompany:myplugin:0.1"</span>
&#125;</pre></div><p class="paragraph"/><blockquote class="note">
Since binary plugins are packaged as JAR files, they are declared as dependencies in the <code>dependencies</code> block,  <em class="italic">not</em>  in the <code>plugins</code> block as you may be naturally inclined to do. The <code>plugins</code> block is used for declaring traditional source plugins packaged as zip files
</blockquote>



                <div style="clear:both;margin-top:15px;"></div>
                
                    <div class="toc-item prev-left"><a href="../guide/security.html">&lt;&lt; <strong>12</strong><span>Security</span></a></div>
                
                    <div class="toc-item next-right"><a href="../guide/webServices.html"><strong>14</strong><span>Web Services</span> >></a></div>
                
                <div style="clear:both"></div>
            </div>
        </td>
        <td id="col2">
            <div class="local clearfix">
                <div class="local-title">
                    <a href="../guide/index.html" target="mainFrame">Quick Reference</a>
                    <span class="toggle">(<a href="#" onclick="localToggle(); return false;">hide</a>)</span>
                </div>
                <div class="menu">
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Command Line</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Command%20Line/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/add-proxy.html">add-proxy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/alias.html">alias</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/bootstrap.html">bootstrap</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/bug-report.html">bug-report</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/clean.html">clean</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/clear-proxy.html">clear-proxy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/compile.html">compile</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/console.html">console</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-app.html">create-app</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-controller.html">create-controller</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-domain-class.html">create-domain-class</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-filters.html">create-filters</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-hibernate-cfg-xml.html">create-hibernate-cfg-xml</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-integration-test.html">create-integration-test</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-multi-project-build.html">create-multi-project-build</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-plugin.html">create-plugin</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-pom.html">create-pom</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-scaffold-controller.html">create-scaffold-controller</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-script.html">create-script</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-service.html">create-service</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-tag-lib.html">create-tag-lib</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/create-unit-test.html">create-unit-test</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/dependency-report.html">dependency-report</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/doc.html">doc</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/generate-all.html">generate-all</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/generate-controller.html">generate-controller</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/generate-views.html">generate-views</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/help.html">help</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/init.html">init</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/install-dependency.html">install-dependency</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/install-plugin.html">install-plugin</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/install-templates.html">install-templates</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/integrate-with.html">integrate-with</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/interactive.html">interactive</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/list-plugin-updates.html">list-plugin-updates</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/list-plugins.html">list-plugins</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/migrate-docs.html">migrate-docs</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/package-plugin.html">package-plugin</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/package.html">package</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/plugin-info.html">plugin-info</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/refresh-dependencies.html">refresh-dependencies</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/remove-proxy.html">remove-proxy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/run-app.html">run-app</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/run-script.html">run-script</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/run-war.html">run-war</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/schema-export.html">schema-export</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/set-proxy.html">set-proxy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/set-version.html">set-version</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/shell.html">shell</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/stats.html">stats</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/stop-app.html">stop-app</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/test-app.html">test-app</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/uninstall-plugin.html">uninstall-plugin</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/upgrade.html">upgrade</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/war.html">war</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Command%20Line/wrapper.html">wrapper</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Constraints</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Constraints/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Constraints/attributes.html">attributes</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/bindable.html">bindable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/blank.html">blank</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/creditCard.html">creditCard</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/email.html">email</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/inList.html">inList</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/matches.html">matches</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/max.html">max</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/maxSize.html">maxSize</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/min.html">min</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/minSize.html">minSize</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/notEqual.html">notEqual</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/nullable.html">nullable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/range.html">range</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/scale.html">scale</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/size.html">size</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/unique.html">unique</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/url.html">url</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/validator.html">validator</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Constraints/widget.html">widget</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Controllers</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Controllers/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Controllers/actionName.html">actionName</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/afterInterceptor.html">afterInterceptor</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/allowedMethods.html">allowedMethods</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/beforeInterceptor.html">beforeInterceptor</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/bindData.html">bindData</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/chain.html">chain</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/controllerName.html">controllerName</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/defaultAction.html">defaultAction</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/flash.html">flash</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/forward.html">forward</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/grailsApplication.html">grailsApplication</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/params.html">params</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/redirect.html">redirect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/render.html">render</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/request.html">request</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/response.html">response</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/servletContext.html">servletContext</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/session.html">session</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/withForm.html">withForm</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Controllers/withFormat.html">withFormat</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Database Mapping</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Database%20Mapping/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/autoImport.html">autoImport</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/autoTimestamp.html">autoTimestamp</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/batchSize.html">batchSize</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/cache.html">cache</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/cascade.html">cascade</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/column.html">column</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/comment.html">comment</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/discriminator.html">discriminator</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/dynamicInsert.html">dynamicInsert</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/dynamicUpdate.html">dynamicUpdate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/fetch.html">fetch</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/id.html">id</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/ignoreNotFound.html">ignoreNotFound</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/indexColumn.html">indexColumn</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/insertable.html">insertable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/joinTable.html">joinTable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/lazy.html">lazy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/order.html">order</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/sort.html">sort</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/table.html">table</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/type.html">type</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/updateable.html">updateable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Database%20Mapping/version.html">version</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Domain Classes</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Domain%20Classes/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/addTo.html">addTo</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/attach.html">attach</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/belongsTo.html">belongsTo</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/clearErrors.html">clearErrors</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/constraints.html">constraints</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/count.html">count</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/countBy.html">countBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/createCriteria.html">createCriteria</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/delete.html">delete</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/discard.html">discard</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/embedded.html">embedded</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/errors.html">errors</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/executeQuery.html">executeQuery</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/executeUpdate.html">executeUpdate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/exists.html">exists</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/fetchMode.html">fetchMode</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/find.html">find</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findAll.html">findAll</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findAllBy.html">findAllBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findAllWhere.html">findAllWhere</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findBy.html">findBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findOrCreateBy.html">findOrCreateBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findOrCreateWhere.html">findOrCreateWhere</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findOrSaveBy.html">findOrSaveBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findOrSaveWhere.html">findOrSaveWhere</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/findWhere.html">findWhere</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/first.html">first</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/get.html">get</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/getAll.html">getAll</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/getDirtyPropertyNames.html">getDirtyPropertyNames</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/getPersistentValue.html">getPersistentValue</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/hasErrors.html">hasErrors</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/hasMany.html">hasMany</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/hasOne.html">hasOne</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/ident.html">ident</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/instanceOf.html">instanceOf</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/isAttached.html">isAttached</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/isDirty.html">isDirty</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/last.html">last</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/list.html">list</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/listOrderBy.html">listOrderBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/load.html">load</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/lock.html">lock</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/mappedBy.html">mappedBy</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/mapping.html">mapping</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/merge.html">merge</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/namedQueries.html">namedQueries</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/properties.html">properties</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/read.html">read</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/refresh.html">refresh</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/removeFrom.html">removeFrom</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/save.html">save</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/transients.html">transients</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/validate.html">validate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/where.html">where</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/whereAny.html">whereAny</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/withCriteria.html">withCriteria</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/withNewSession.html">withNewSession</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/withSession.html">withSession</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Domain%20Classes/withTransaction.html">withTransaction</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Plug-ins</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Plug-ins/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/URL%20mappings.html">URL mappings</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/codecs.html">codecs</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/controllers.html">controllers</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/core.html">core</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/dataSource.html">dataSource</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/domainClasses.html">domainClasses</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/filters.html">filters</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/hibernate.html">hibernate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/i18n.html">i18n</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/logging.html">logging</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/scaffolding.html">scaffolding</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/services.html">services</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/servlets.html">servlets</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Plug-ins/web%20flow.html">web flow</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Services</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Services/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Services/scope.html">scope</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Services/transactional.html">transactional</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Servlet API</h1><div class="menu-sub">
                        
                            
                            <div class="menu-item"><a href="../ref/Servlet%20API/request.html">request</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Servlet%20API/response.html">response</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Servlet%20API/servletContext.html">servletContext</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Servlet%20API/session.html">session</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Tag Libraries</h1><div class="menu-sub">
                        
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/Usage.html">Usage</a></div>
                            
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/actionName.html">actionName</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/controllerName.html">controllerName</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/flash.html">flash</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/pageScope.html">pageScope</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/params.html">params</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/request.html">request</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/response.html">response</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/servletContext.html">servletContext</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tag%20Libraries/session.html">session</a>
                            </div>
                            
                            </div>
                    </div>
                    
                    <div class="menu-block"><h1 class="menu-title" onclick="toggleRef(this.parentNode.childNodes[1])">Tags</h1><div class="menu-sub">
                        
                            
                            <div class="menu-item"><a href="../ref/Tags/actionSubmit.html">actionSubmit</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/actionSubmitImage.html">actionSubmitImage</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/applyLayout.html">applyLayout</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/checkBox.html">checkBox</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/collect.html">collect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/cookie.html">cookie</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/country.html">country</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/countrySelect.html">countrySelect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/createLink.html">createLink</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/createLinkTo.html">createLinkTo</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/currencySelect.html">currencySelect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/datePicker.html">datePicker</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/each.html">each</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/eachError.html">eachError</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/else.html">else</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/elseif.html">elseif</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/external.html">external</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/field.html">field</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/fieldValue.html">fieldValue</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/findAll.html">findAll</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/form.html">form</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/formRemote.html">formRemote</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/formatBoolean.html">formatBoolean</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/formatDate.html">formatDate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/formatNumber.html">formatNumber</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/grep.html">grep</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/hasErrors.html">hasErrors</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/header.html">header</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/hiddenField.html">hiddenField</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/if.html">if</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/img.html">img</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/include.html">include</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/isAvailable.html">isAvailable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/isNotAvailable.html">isNotAvailable</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/javascript.html">javascript</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/join.html">join</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/layoutBody.html">layoutBody</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/layoutHead.html">layoutHead</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/layoutTitle.html">layoutTitle</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/link.html">link</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/localeSelect.html">localeSelect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/message.html">message</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/meta.html">meta</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/pageProperty.html">pageProperty</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/paginate.html">paginate</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/passwordField.html">passwordField</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/radio.html">radio</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/radioGroup.html">radioGroup</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/remoteField.html">remoteField</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/remoteFunction.html">remoteFunction</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/remoteLink.html">remoteLink</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/render.html">render</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/renderErrors.html">renderErrors</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/resource.html">resource</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/select.html">select</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/set.html">set</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/setProvider.html">setProvider</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/sortableColumn.html">sortableColumn</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/submitButton.html">submitButton</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/submitToRemote.html">submitToRemote</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/textArea.html">textArea</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/textField.html">textField</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/timeZoneSelect.html">timeZoneSelect</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/unless.html">unless</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/uploadForm.html">uploadForm</a>
                            </div>
                            
                            <div class="menu-item"><a href="../ref/Tags/while.html">while</a>
                            </div>
                            
                            </div>
                    </div>
                    
                </div>
            </div>
        </td>
    </tr>
</table>

<div id="footer">
    Copies of this document may be made for your own use and for distribution to others, provided that you do not charge any fee for such copies and further provided that each copy contains this Copyright Notice, whether distributed in print or electronically.
    Sponsored by <a href="http://springsource.com">SpringSource</a>
</div>

<script type="text/javascript" src="../js/docs.js"></script>

</body>
</html>
